define("vs/cssMode-CjiAH6dQ",["module","exports","./workers-DcJshg-q","./lspLanguageFeatures-kM9O9rjY","./editor.api-CalNCsUg"],function(e,t,r,n,o){"use strict";class i{constructor(e){this._defaults=e,this._worker=null,this._client=null,this._idleCheckInterval=window.setInterval(()=>this._checkIfIdle(),3e4),this._lastUsedTime=0,this._configChangeListener=this._defaults.onDidChange(()=>this._stopWorker())}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}dispose(){clearInterval(this._idleCheckInterval),this._configChangeListener.dispose(),this._stopWorker()}_checkIfIdle(){this._worker&&Date.now()-this._lastUsedTime>12e4&&this._stopWorker()}_getClient(){return this._lastUsedTime=Date.now(),this._client||(this._worker=r.createWebWorker({moduleId:"vs/language/css/cssWorker",createWorker:()=>new Worker(new URL(""+new URL(require.toUrl("./assets/css.worker-HnVq6Ewq.js"),document.baseURI).href,new URL(e.uri,document.baseURI).href),{type:"module"}),label:this._defaults.languageId,createData:{options:this._defaults.options,languageId:this._defaults.languageId}}),this._client=this._worker.getProxy()),this._client}getLanguageServiceWorker(...e){let t;return this._getClient().then(e=>{t=e}).then(t=>{if(this._worker)return this._worker.withSyncedResources(e)}).then(e=>t)}}function s(e){return{dispose:()=>a(e)}}function a(e){for(;e.length;)e.pop().dispose()}t.CompletionAdapter=n.CompletionAdapter,t.DefinitionAdapter=n.DefinitionAdapter,t.DiagnosticsAdapter=n.DiagnosticsAdapter,t.DocumentColorAdapter=n.DocumentColorAdapter,t.DocumentFormattingEditProvider=n.DocumentFormattingEditProvider,t.DocumentHighlightAdapter=n.DocumentHighlightAdapter,t.DocumentLinkAdapter=n.DocumentLinkAdapter,t.DocumentRangeFormattingEditProvider=n.DocumentRangeFormattingEditProvider,t.DocumentSymbolAdapter=n.DocumentSymbolAdapter,t.FoldingRangeAdapter=n.FoldingRangeAdapter,t.HoverAdapter=n.HoverAdapter,t.ReferenceAdapter=n.ReferenceAdapter,t.RenameAdapter=n.RenameAdapter,t.SelectionRangeAdapter=n.SelectionRangeAdapter,t.fromPosition=n.fromPosition,t.fromRange=n.fromRange,t.toRange=n.toRange,t.toTextEdit=n.toTextEdit,t.WorkerManager=i,t.setupMode=function(e){const t=[],r=[],g=new i(e);t.push(g);const d=(...e)=>g.getLanguageServiceWorker(...e);return function(){const{languageId:t,modeConfiguration:i}=e;a(r),i.completionItems&&r.push(o.languages.registerCompletionItemProvider(t,new n.CompletionAdapter(d,["/","-",":"]))),i.hovers&&r.push(o.languages.registerHoverProvider(t,new n.HoverAdapter(d))),i.documentHighlights&&r.push(o.languages.registerDocumentHighlightProvider(t,new n.DocumentHighlightAdapter(d))),i.definitions&&r.push(o.languages.registerDefinitionProvider(t,new n.DefinitionAdapter(d))),i.references&&r.push(o.languages.registerReferenceProvider(t,new n.ReferenceAdapter(d))),i.documentSymbols&&r.push(o.languages.registerDocumentSymbolProvider(t,new n.DocumentSymbolAdapter(d))),i.rename&&r.push(o.languages.registerRenameProvider(t,new n.RenameAdapter(d))),i.colors&&r.push(o.languages.registerColorProvider(t,new n.DocumentColorAdapter(d))),i.foldingRanges&&r.push(o.languages.registerFoldingRangeProvider(t,new n.FoldingRangeAdapter(d))),i.diagnostics&&r.push(new n.DiagnosticsAdapter(t,d,e.onDidChange)),i.selectionRanges&&r.push(o.languages.registerSelectionRangeProvider(t,new n.SelectionRangeAdapter(d))),i.documentFormattingEdits&&r.push(o.languages.registerDocumentFormattingEditProvider(t,new n.DocumentFormattingEditProvider(d))),i.documentRangeFormattingEdits&&r.push(o.languages.registerDocumentRangeFormattingEditProvider(t,new n.DocumentRangeFormattingEditProvider(d)))}(),t.push(s(r)),s(t)},Object.defineProperty(t,Symbol.toStringTag,{value:"Module"})});